#include <stdio.h>
#include <stdlib.h>
#include <pthread.h>

pthread_t ntid;

void printids(const char *s)
{
        pthread_t tid;

        tid = pthread_self();
        printf("%s tid %u (0x%x)\n", s, (unsigned int)tid, (unsigned int)tid);
}

void * thr_fn(void *arg)
{
        printids("new thread: ");
        return((void *)0);
}

int main(void)
{
        pthread_create(&ntid, NULL, &thr_fn, NULL);
//        pthread_create(&ntid, NULL, &thr_fn, NULL);
        printids("main thread:");
        sleep(1);
        exit(0);
}
